package com.jt.springboot_ssm.service;

import com.jt.springboot_ssm.mapper.UserMapper;
import com.jt.springboot_ssm.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;

import java.util.List;
@Service//交给spring容器管理
//@Component//业务层
public class UserServiceimpl implements UserService {
    @Autowired
    private UserMapper userMapper;//代理对象,JDK动态代理
    @Override
    public List<User> findAll() {

        return userMapper.findAll();
    }
}
